<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title>E-mail address verification</title>
<style type="text/css">
 span.bad {color:red; font-weight:bold;}
 span.good {color:green; font-weight:bold;}
</style>
</head>
<body>
<h1>E-mail address verification</h1>

    <form name="form1" method="post" action="<?php echo $_SERVER['SCRIPT_NAME']; ?>">
        <input name="email" type="text" id="email" value="<?php echo @$_REQUEST['email']; ?>" size="40" />
        <input type="submit" name="Submit" value="Check me!" />
    </form>

<?php
# Get this function at http://www.tienhuis.nl/files/email_verify_source.php
# and save as VerifyEmailAddress.php
require_once "VerifyEmailAddress.php";

if(@$_REQUEST['email']) {
    # Do the actual check and notify if any errors come back.
    # READ THE COMMENTS IN THE FUNCTION, THIS IS SITE SPECIFIC!
    # WILL NOT WORK WITHOUT SITE LOCAL MODIFICATION.
    # You have been warned ;-)
    $error = validateEmail($_REQUEST['email'], true, true, 'postmaster@cajones.org', 'cajones.org', true);
    if ($error) {
        echo "<span class='bad'>$error</span>";
    } else {
        echo "<span class='good'>This address appears to be correct!</span>";
    }
}
?>

</body>
</html>